{extend name="iframe" /}

{block name="body"}
<div class="layui-fluid">
    <div class="layui-row layui-col-space15">
        <div class="layui-form" lay-filter="layuiadmin-app-form-list" id="layuiadmin-app-form-list">
            <form action="{:request()->url()}" method="post" class="xn_ajax" data-type="open">
                <div class="layui-form-item">
                    <label class="layui-form-label">上级ID</label>
                    <div class="layui-input-block">
                        <select name="pid" lay-verify="required">
                            <option value="0">--顶级分类--</option>
                            {foreach name="list" item="vo"}
                            <option value="{$vo.id}" {if condition="$pid eq $vo['id']"}selected{/if} >{$vo._name}</option>
                            {/foreach}
                        </select>
                    </div>
                </div>

                <div class="layui-form-item">
                    <label class="layui-form-label">规则</label>
                    <div class="layui-input-block">
                        <textarea name="content" placeholder="每组的第一行加 * 号则为该组父节点，多组规则请用回车隔开
每行再以 ; 符号隔开，第一个元素为后面元素的父节点" class="layui-textarea" style="height: 250px">{$data.content}</textarea>
                    </div>
                </div>
                <div class="layui-form-item">
                    <div class="layui-input-block">
                        <button type="submit" lay-submit class="layui-btn">保存</button>
                        <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                    </div>
                </div>
                <div class="layui-form-item">
                    <label class="layui-form-label">规则示例:</label>
                    <div class="layui-input-block" style="color: #999999">
                        *文章管理|admin/article<br>
                        文章列表|admin/article/index;添加|admin/article/add;编辑|admin/article/edit;删除|admin/article/delete<br>
                        文章分类|admin/article_class/index;添加|admin/article/add;编辑|admin/article/edit;删除|admin/article/delete<br>
                        <br>
                        单页管理|admin/page/index;添加|admin/page/add;编辑|admin/page/edit;删除|admin/page/delete;排序|admin/page/sort
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
{/block}